import { IFeidaoAiBrowserComponent } from '@dfeidao/atom-web/interfaces';
import nodejs from '@dfeidao/atom-web/msg/nodejs';
import render from '@dfeidao/atom-web/render/render';
import p001 from './p001';
import p002 from './p002';
import p003 from './p003';
import p004 from './p004';

export default async function a002(fd: IFeidaoAiBrowserComponent) {// 渲染下拉框数据
	// todo
	console.log('zj-000004:a002----start');
	const res = await nodejs<{ com: Array<{}>; com1: Array<{}>; com2: Array<{}>; data: Array<{}> }>('wyf-hManager/zj-000004/s001', {});
	console.log(res);
	// 渲染隐患源评价级别下拉框数据
	render(fd, res.com, p001, 'p001', 'after');
	// 渲染隐患源管控层级下拉框数据
	render(fd, res.com1, p002, 'p002', 'after');
	// 获取隐患源管控级别下拉框数据
	render(fd, res.com2, p003, 'p003', 'after');
	// 获取负责部门下拉框数据
	render(fd, res.data, p004, 'p004', 'after');

	console.log('zj-000004:a002----end');
	return res;
}
